/*
* TFRuleCheckerImpl.h
*
* Implements TFRuleCheckerInterface
*
* Author: Rapid Dojo
* Date: Oct 19, 2007
*/

#include "TFRuleCheckerInterface.h"
#include "TFGameTurn.h"


// Moved Move_Struct definition to TFGameTurn -DPM
const int POINTS_TO_CAPTURE_TROOP = 3;
const int POINTS_TO_CAPTURE_BARRICADE = 2;
const int POINTS_TO_CAPTURE_FLAG = 3;
const int POINTS_TO_CAPTURE_FLAG_BARRICADE = 1;
const int POINTS_TO_MOVE_THROUGH_YOUR_TROOP = 2;


class TFRuleCheckerImpl: public TFRuleCheckerInterface
{
public:

	TFRuleCheckerImpl ();
	virtual ~TFRuleCheckerImpl ();

	bool LegalMove(TFBoard *iCurrentBoard, TFGameTurn* myTurn, bool spendPoints = false);
	bool CanPlaceBarricade(int numPointsThisTurn);
	bool CanPlaceFlagFortification(int numPointsThisTurn);
	int CostToCapture(TFGamePiece *iPiece, int yourColor);
	bool CanPlacePieceHere(int row, int col,TF_ADD_PIECE piece, TF_PLAYERS color, TFBoard *iCurrentBoard);

	HRESULT CheckGame();

};
